package com.lory.service.impl;

import com.lory.pojo.Order;
import com.lory.pojo.Product;
import com.lory.service.OrderService;
import com.lory.service.ProductService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cloud.client.ServiceInstance;
import org.springframework.cloud.client.discovery.DiscoveryClient;
import org.springframework.cloud.client.loadbalancer.LoadBalancerClient;
import org.springframework.core.ParameterizedTypeReference;
import org.springframework.http.HttpMethod;
import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Service;
import org.springframework.util.CollectionUtils;
import org.springframework.web.client.RestTemplate;

import java.util.List;

/**
 * @ClassName OrderServiceImpl
 * @Description TODO
 * @Author lory
 * @Date 2021/7/22 15:27
 * @Version TODO
 **/
@Service
public class OrderServiceImpl implements OrderService {

    @Autowired
    private ProductService productService;

    @Override
    public Order selectOrderById(Integer id) {
        return new Order(id, "111", "上海", 5555d, productService.selectProductList());
    }


}
